From: Giovanni Campagna Date: Mon, 28 Jan 2013 11:09:17 +0000 (+0100) Subject: MessageTray: disconnect signal to notification early X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~1013^2^2~5011 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=4545719e18239edfb276c3ede7a76ca401fddc1e;p=gnome-shell.git MessageTray: disconnect signal to notification early Similar to the previous patch, this adds robustness and prevents more stacktraces and confusion in the state machine. https://bugzilla.gnome.org/show_bug.cgi?id=692693 --- diff --git a/js/ui/messageTray.js b/js/ui/messageTray.js index 277b7e30b..79a91df3c 100644 --- a/js/ui/messageTray.js +++ b/js/ui/messageTray.js @@ -2384,11 +2384,18 @@ const MessageTray = new Lang.Class({ this.idleMonitor.disconnect(this._idleMonitorBecameActiveId); this._idleMonitorBecameActiveId = 0; } - if (this._notificationExpandedId) { this._notification.disconnect(this._notificationExpandedId); this._notificationExpandedId = 0; } + if (this._notificationClickedId) { + this._notification.disconnect(this._notificationClickedId); + this._notificationClickedId = 0; + } + if (this._notificationUnfocusedId) { + this._notification.disconnect(this._notificationUnfocusedId); + this._notificationUnfocusedId = 0; + } if (this._notificationRemoved) { Tweener.removeTweens(this._notificationWidget); @@ -2411,10 +2418,7 @@ const MessageTray = new Lang.Class({ _hideNotificationCompleted: function() { this._notification.collapseCompleted(); - this._notification.disconnect(this._notificationClickedId); - this._notificationClickedId = 0; - this._notification.disconnect(this._notificationUnfocusedId); - this._notificationUnfocusedId = 0; + let notification = this._notification; this._notification = null; if (notification.isTransient)